# coding=utf-8
from framework.base_page import BasePage

class AppointAgentPage(BasePage):
    btn_choose_service = "xpath=>//input[@type='checkbox']"
    btn_submit = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[3]/button"
    btn_email = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[4]/div[2]/div/div"
    input_email = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[4]/div[2]/div/div/input"
    btn_select_yes = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[3]/div[2]/div/label[1]/span[1]/input"
    btn_select_no = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[3]/div[2]/div/label[2]/span[1]/input"
    btn_payer = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[2]/div[2]"
    input_payer = "xpath=>//*[@id='instruction']"
    btn_eports = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[1]/div[2]/div/label[1]/span[1]/input"
    btn_agent = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[1]/div[2]/div/label[2]/span[1]/input"
    btn_address = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div/div/div/form/div[2]/div[2]/div/div[4]/div[2]/div/div/div"
    input_address = "xpath=>//*[@id='addressInfo']"

    def click_choose_service(self):
        self.click(self.btn_choose_service)
        self.sleep(2)

    def click_submit(self):
        self.click(self.btn_submit)
        self.sleep(2)

    def click_email(self):
        self.click(self.btn_email)
        self.sleep(2)

    def type_input_email(self, text):
        self.type(self.input_email,text)
        self.sleep(2)

    def click_select_yes(self):
        self.click(self.btn_select_yes)
        self.sleep(2)

    def click_select_no(self):
        self.click(self.btn_select_no)
        self.sleep(2)

    def click_payer(self):
        self.click(self.btn_payer)
        self.sleep(2)

    def type_input_payer(self,text):
        self.type(self.input_payer,text)
        self.sleep(2)

    def click_eports(self):
        self.click(self.btn_eports)
        self.sleep(2)

    def click_agent(self):
        self.click(self.btn_agent)
        self.sleep(2)

    def click_address(self):
        self.click(self.btn_address)
        self.sleep(2)

    def type_input_address(self,text):
        self.type(self.input_address,text)
        self.sleep(2)